package com.zyy.visitor.demo01;

/**
 * @Description: 类描述
 * @Author: zyy
 * @Date: 2023/08/09 22:44
 */
public class Client {
    public static void main(String[] args) {
        Cat cat = new Cat();
        Dog dog = new Dog();

        Home home = new Home();
        home.add(cat);
        home.add(dog);

        Owner owner = new Owner();
        home.action(owner);

        System.out.println("==========");

        SomeOne someOne = new SomeOne();
        home.action(someOne);
    }
}
